package com.engine.salary.entity.salaryarchive.dto;

import com.cloudstore.eccom.pc.table.WeaTableType;
import com.engine.salary.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Date;
import java.util.Set;

/**
 * 薪资档案列表
 * <p>Copyright: Copyright (c) 2022</p>
 * <p>Company: 泛微软件</p>
 *
 * @author qiantao
 * @version 1.0
 **/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@SalaryTable(pageId = "a4f85287-9876-4d11-adn9-7d06e54y6rj8", tableType = WeaTableType.CHECKBOX, operates = {
        @SalaryTableOperate(index = "0", text = "编辑"),
        @SalaryTableOperate(index = "1", text = "删除")
})
@Auth(page = "salaryArchive")
public class SalaryArchiveListDTO {

    @TableTitle(title = "id", dataIndex = "id", key = "id")
    private Long id;

    @TableTitle(title = "人员信息表的主键id", dataIndex = "employeeId", key = "employeeId")
    @AuthField(fieldType = "employeeId")
    private Long employeeId;

    private Integer employeeType;

    /**
     * 姓名
     */
    @TableTitle(title = "姓名", dataIndex = "username", key = "username")
    @I18n
    private String username;

    /**
     * 个税扣缴义务人
     */
    @TableTitle(title = "个税扣缴义务人", dataIndex = "taxAgentName", key = "taxAgentName")
    private String taxAgentName;
    @AuthField(fieldType = "taxAgentId")
    private Long taxAgentId;

    /**
     * 分部
     */
    @TableTitle(title = "分部", dataIndex = "subcompanyName", key = "subcompanyName")
    @I18n
    private String subcompanyName;

    /**
     * 部门
     */
    @TableTitle(title = "部门", dataIndex = "departmentName", key = "departmentName")
    @I18n
    private String departmentName;

    /**
     * 电话
     */
    @TableTitle(title = "电话", dataIndex = "mobile", key = "mobile")
    private String mobile;

    /**
     * 入职日期
     */
    private String companystartdate;

    /**
     * 离职日期
     */
    private String dismissdate;

    /**
     * 工号
     */
    @TableTitle(title = "工号", dataIndex = "workcode", key = "workcode")
    private String workcode;

    /**
     * 证件号码
     */
    @TableTitle(title = "证件号码", dataIndex = "idNo", key = "idNo")
    private String idNo;

    /**
     * 员工状态
     */
    @TableTitle(title = "员工状态", dataIndex = "employeeStatus", key = "employeeStatus")
    private String employeeStatus;

    /**
     * 起始发薪日期
     */
    @TableTitle(title = "起始发薪日期", dataIndex = "payStartDate", key = "payStartDate")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date payStartDate;

    /**
     * 最后发薪日期
     */
    @TableTitle(title = "最后发薪日期", dataIndex = "payEndDate", key = "payEndDate")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date payEndDate;

    /**
     * 档案状态
     * SalaryArchiveStatusEnum
     */
    private String archiveStatus;

    //主次账号   0/null：主账号    1：次账号
    private Integer accountType;

    private Set<String> opts;

}
